import request from '../utils/request.js';

export const loginAPI = (data) => request.post('/v1_0/authorizations', data);

export const getUserInfoAPI = () => {
    return request.get('/v1_0/user')
  }

export const getUserProfileAPI = () => {
    return request.get('/v1_0/user/profile')
}

export const updateUserProfileAPI = obj => {
  return request.patch('/v1_0/user/profile', obj)
}

export const updateUserAvatarAPI = fd => {
  return request.patch('/v1_0/user/photo', fd)
}